this._parentalControlsManager.disconnect(this._appFilterChangedId);
this._appFilterChangedId = 0;
}
+
+ if (this._swipeTracker) {
+ this._swipeTracker.destroy();
+ delete this._swipeTracker;
+ }
+
this._removeDelayedMove();
this._disconnectDnD();
}
this._orientation = Clutter.Orientation.VERTICAL;
this._enabled = true;
- global.stage.connect('captured-event::touchpad', this._handleEvent.bind(this));
+ this._stageCaptureEvent =
+ global.stage.connect('captured-event::touchpad', this._handleEvent.bind(this));
}
get enabled() {
return Clutter.EVENT_STOP;
}
+
+ destroy() {
+ if (this._stageCaptureEvent) {
+ global.stage.disconnect(this._stageCaptureEvent);
+ delete this._stageCaptureEvent;
+ }
+ }
});
const TouchSwipeGesture = GObject.registerClass({
this._velocity = 0;
this._state = State.SCROLLING;
}
+
+ destroy() {
+ if (this._touchpadGesture) {
+ this._touchpadGesture.destroy();
+ delete this._touchpadGesture;
+ }
+
+ if (this._touchGesture) {
+ global.stage.remove_action(this._touchGesture);
+ delete this._touchGesture;
+ }
+ }
});